/* -*- Mode:Prolog; coding:ISO-8859-1; -*- */

%@  @item bb_set_value(+Key, +Value), bb_get_value(+Key, -Value)  
%@  Same semantics as Sicstus's bb_put(Key, Value) and bb_get(Key, Value)
%:- if(current_prolog_flag(dialect, yap)).
%        %TODO: check whether there's a better way to do this.
%        :- dynamic myvalue/2.
%
%        bb_set_value(Key, Val) :- 
%                retractall(myvalue(Key, _Val)), 
%                assert(myvalue(Key, Val)).
%        
%        bb_get_value(Key, Val) :- 
%                myvalue(Key, Val), !.
%
%        bb_get_value(_Key, empty).
%
%:- elif(current_prolog_flag(dialect, sicstus)).

        bb_set_value(Key, Value) :-
                bb_put(Key, Value).    

        bb_get_value(Key, Value) :-
                bb_get(Key, Value), !.   
        
        bb_get_value(_Key, empty).

%:- endif.

